package com.viking.car;


public class Message {
    private MessageHeader messageHeader;
    private MessageBody messageBody;
    private MessageFooter messageFooter;

    public Message() {
    }

    public Message(MessageHeader messageHeader, MessageBody messageBody, MessageFooter messageFooter) {
        this.messageHeader = messageHeader;
        this.messageBody = messageBody;
        this.messageFooter = messageFooter;
    }

    public MessageHeader getMessageHeader() {
        return messageHeader;
    }

    public void setMessageHeader(MessageHeader messageHeader) {
        this.messageHeader = messageHeader;
    }

    public MessageBody getMessageBody() {
        return messageBody;
    }

    public void setMessageBody(MessageBody messageBody) {
        this.messageBody = messageBody;
    }

    public MessageFooter getMessageFooter() {
        return messageFooter;
    }

    public void setMessageFooter(MessageFooter messageFooter) {
        this.messageFooter = messageFooter;
    }

    @Override
    public String toString() {
        return "{"
                + messageHeader +
                ", " + messageBody +
                ", " + messageFooter +
                '}';
    }
}
